<template>
    <div class="li">
        <div class="label" :style="{'width':labelWidth}">{{label}}</div>
        <div class="text">
            <slot></slot>
        </div>
    </div>
</template>

<script setup lang="ts">
const props = withDefaults(defineProps<{
    label?: string
    labelWidth?:string,
}>(), {
    label: '',
    labelWidth:'80px'
})
</script>

<style scoped lang="scss">
.li {
    display: flex;
    justify-content: center;
    margin-bottom: 10px;

    .label{
        flex-shrink: 0;
        text-align: right;
        margin-right: 20px;
        box-sizing: border-box;
        //color: var(--mi-text-color-secondary);
    }
    .text{
        min-width: 0;
        flex: 1;
        word-break: break-all;
        color: #333;
    }
}
</style>
